using System.ComponentModel.DataAnnotations.Schema;
using System.Data.Entity.ModelConfiguration;

namespace ConsoleApplication2.Models.Mapping
{
    public class scidMap : EntityTypeConfiguration<scid>
    {
        public scidMap()
        {
            // Primary Key
            this.HasKey(t => t.id_cnt);

            // Properties
            this.Property(t => t.id_cnt)
                .HasDatabaseGeneratedOption(DatabaseGeneratedOption.None);

            this.Property(t => t.time1)
                .IsFixedLength()
                .HasMaxLength(8)
                .IsRowVersion();

            // Table & Column Mappings
            this.ToTable("scids");
            this.Property(t => t.id_cnt).HasColumnName("id_cnt");
            this.Property(t => t.trans_cnt).HasColumnName("trans_cnt");
            this.Property(t => t.oper_cnt).HasColumnName("oper_cnt");
            this.Property(t => t.app_cnt).HasColumnName("app_cnt");
            this.Property(t => t.plan_cnt).HasColumnName("plan_cnt");
            this.Property(t => t.spon_cnt).HasColumnName("spon_cnt");
            this.Property(t => t.doct_cnt).HasColumnName("doct_cnt");
            this.Property(t => t.exp_cnt).HasColumnName("exp_cnt");
            this.Property(t => t.clm_cnt).HasColumnName("clm_cnt");
            this.Property(t => t.comp_cnt).HasColumnName("comp_cnt");
            this.Property(t => t.ins_cnt).HasColumnName("ins_cnt");
            this.Property(t => t.user_cnt).HasColumnName("user_cnt");
            this.Property(t => t.phn_cnt).HasColumnName("phn_cnt");
            this.Property(t => t.prc_cnt).HasColumnName("prc_cnt");
            this.Property(t => t.drug_cnt).HasColumnName("drug_cnt");
            this.Property(t => t.vc_cnt).HasColumnName("vc_cnt");
            this.Property(t => t.magcnt).HasColumnName("magcnt");
            this.Property(t => t.genslidcnt).HasColumnName("genslidcnt");
            this.Property(t => t.planno_cnt).HasColumnName("planno_cnt");
            this.Property(t => t.ref_cnt).HasColumnName("ref_cnt");
            this.Property(t => t.lett_cnt).HasColumnName("lett_cnt");
            this.Property(t => t.pay_cnt).HasColumnName("pay_cnt");
            this.Property(t => t.adj_cnt).HasColumnName("adj_cnt");
            this.Property(t => t.class_cnt).HasColumnName("class_cnt");
            this.Property(t => t.tel_cnt).HasColumnName("tel_cnt");
            this.Property(t => t.perio_cnt).HasColumnName("perio_cnt");
            this.Property(t => t.pre_cnt).HasColumnName("pre_cnt");
            this.Property(t => t.cat_cnt).HasColumnName("cat_cnt");
            this.Property(t => t.actran_cnt).HasColumnName("actran_cnt");
            this.Property(t => t.acct_cnt).HasColumnName("acct_cnt");
            this.Property(t => t.lb_cnt).HasColumnName("lb_cnt");
            this.Property(t => t.lbdict_cnt).HasColumnName("lbdict_cnt");
            this.Property(t => t.mddrug_cnt).HasColumnName("mddrug_cnt");
            this.Property(t => t.report_cnt).HasColumnName("report_cnt");
            this.Property(t => t.inspay_cnt).HasColumnName("inspay_cnt");
            this.Property(t => t.gridid_cnt).HasColumnName("gridid_cnt");
            this.Property(t => t.crit_cnt).HasColumnName("crit_cnt");
            this.Property(t => t.pcode_cnt).HasColumnName("pcode_cnt");
            this.Property(t => t.udfgrp_cnt).HasColumnName("udfgrp_cnt");
            this.Property(t => t.pcat_cnt).HasColumnName("pcat_cnt");
            this.Property(t => t.pser_cnt).HasColumnName("pser_cnt");
            this.Property(t => t.pres_cnt).HasColumnName("pres_cnt");
            this.Property(t => t.restbl_cnt).HasColumnName("restbl_cnt");
            this.Property(t => t.radformcnt).HasColumnName("radformcnt");
            this.Property(t => t.radtestcnt).HasColumnName("radtestcnt");
            this.Property(t => t.recall_cnt).HasColumnName("recall_cnt");
            this.Property(t => t.preaai_cnt).HasColumnName("preaai_cnt");
            this.Property(t => t.nat_cnt).HasColumnName("nat_cnt");
            this.Property(t => t.vac_cnt).HasColumnName("vac_cnt");
            this.Property(t => t.time1).HasColumnName("time1");
        }
    }
}
